import request from '@/utils/request';

export type CommonIssueType = {
  id: number;
  commonProblem: string;
  questionReply: string;
  state: string;
  releaseTime: string;
  publisherId: number;
  publisher: string;
  createTime: string;
  updateTime?: string | null;
  views?: number;
};

export async function findCommonIssue(data: any): Promise<any> {
  return request.post(`/portal/findPolicyCommonQuestionList`, {
    data,
  });
}

export async function findIssueById(params: any): Promise<any> {
  return request.get(`/portal/findPolicyCommonQuestionById`, {
    params,
  });
}
